function getCity() {
    let defaultCity = "武汉"
    if (localStorage.getItem("city")) {
        defaultCity = localStorage.getItem("city");
    }
    return defaultCity;
}
const CityHook = {
    state: {
        city: getCity()
    },
    mutations: {
        changeCity(state, val) {
            localStorage.setItem("city", val);
            state.city = val
        }
    },
    actions: {
    },
}
export default CityHook;